home *** CD-ROM | disk | FTP | other *** search
/ ADA Programming Guide / ADA Programming Guide.iso / ada_gnu / adainc / a-decima.adb < prev    next >
Text File  |  1996-01-30  |  3KB  |  55 lines

  1. ------------------------------------------------------------------------------
  2. --                                                                          --
  3. --                         GNAT RUNTIME COMPONENTS                          --
  4. --                                                                          --
  5. --                          A D A . D E C I M A L                           --
  6. --                                                                          --
  7. --                                 B o d y                                  --
  8. --                                                                          --
  9. --                            $Revision: 1.3 $                              --
  10. --                                                                          --
  11. --           Copyright (c) 1992,1993,1994 NYU, All Rights Reserved          --
  12. --                                                                          --
  13. -- The GNAT library is free software; you can redistribute it and/or modify --
  14. -- it under terms of the GNU Library General Public License as published by --
  15. -- the Free Software  Foundation; either version 2, or (at your option) any --
  16. -- later version.  The GNAT library is distributed in the hope that it will --
  17. -- be useful, but WITHOUT ANY WARRANTY;  without even  the implied warranty --
  18. -- of MERCHANTABILITY  or  FITNESS FOR  A PARTICULAR PURPOSE.  See the  GNU --
  19. -- Library  General  Public  License for  more  details.  You  should  have --
  20. -- received  a copy of the GNU  Library  General Public License  along with --
  21. -- the GNAT library;  see the file  COPYING.LIB.  If not, write to the Free --
  22. -- Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.        --
  23. --                                                                          --
  24. ------------------------------------------------------------------------------
  25.  
  26. package body Ada.Decimal is
  27.  
  28.    ------------
  29.    -- Divide --
  30.    ------------
  31.  
  32.    procedure Divide
  33.      (Dividend  : in Dividend_Type;
  34.       Divisor   : in Divisor_Type;
  35.       Quotient  : out Quotient_Type;
  36.       Remainder : out Remainder_Type)
  37.    is
  38.       --  We have a nested procedure that is the actual intrinsic divide.
  39.       --  This is required because in the current RM, Divide itself does
  40.       --  not have convention Intrinsic.
  41.  
  42.       procedure Divide
  43.         (Dividend  : in Dividend_Type;
  44.          Divisor   : in Divisor_Type;
  45.          Quotient  : out Quotient_Type;
  46.          Remainder : out Remainder_Type);
  47.  
  48.       pragma Import (Intrinsic, Divide);
  49.  
  50.    begin
  51.       Divide (Dividend, Divisor, Quotient, Remainder);
  52.    end Divide;
  53.  
  54. end Ada.Decimal;
  55.